package com.module.antiFake;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import base.util.ConstantUnit;
import base.util.Page;

import com.module.antiFake.manager.AntiFakeScanHistoryManager;
import com.module.antiFake.vo.AntiFakeScanHistory;
import com.module.sys.LoginSession;

import flex.messaging.io.amf.ASObject;

/**
 * 扫码列表查询;
 * @author wult
 *
 */
public class AntiFakeScanHistoryService {
	/**
	 * 分页查询编号说明信息
	 * @param log 编号说明对象
	 * @param start 开始分页行
	 * @param limit 每一页的最大行数
	 * @return 对象结果集
	 * @throws Exception
	 */
	 public Page toList(AntiFakeScanHistory history,final Integer start,final Integer limit) throws Exception{
		Page page = new Page();
        page.setStart(start);
        page.setLimit(limit);     
        history.setOrgid(LoginSession.getOrgid());
//        Map<String,Object> map = new HashMap<String,Object>();
//	    map.put(ConstantUnit.O_PT, "listScanHistoryBySearch");
// 	    map.put("page", page);
// 	    map.put("antiFakeScanHistory", history);
//	    return AntiFakeSocketClient.returnValue(map).getPage();
        AntiFakeScanHistoryManager antiFakeScanHistoryManager = AntiFakeScanHistoryManager.getInstance();
        page = antiFakeScanHistoryManager.findScanHistoryFromWebSearch(history, page);
        return page;
	}
}
